package com.zhz.livegoods.buyaction.dao.impl;

import com.zhz.livegoods.buyaction.dao.ItemDao;
import com.zhz.livegoods.pojo.Item;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.stereotype.Repository;

/**
 * @author zhz
 * @date 2020/08/10
 **/
@Repository
public class ItemDaoImpl implements ItemDao {
    @Autowired
    private RedisTemplate<String, Object> redisTemplate;
    @Override
    public Item get(String key) {
        return (Item)redisTemplate.opsForValue().get(key);
    }
}
